<template>
  <div class="home-center-view">
    <h1>我的页面，个人中心</h1>

    <div v-if="token">
      <h1>用户已经登录</h1>
    </div>

    <div v-else>
      <h1>
        没有登录，<router-link
          :to="{
            name: 'login',
            query: {
              redirect: '/center',
            },
          }"
          >请登录</router-link
        >
      </h1>
    </div>
  </div>
</template>

<script>
// import axios from "axios";

import { mapState } from "vuex";
export default {
  name: "HomeCenterView",

  computed: {
    ...mapState(["token"]),
  },

  created() {
    // const url =
    //   "/api/ajax/moreCinemas?movieId=0&day=2022-08-22&offset=0&limit=20&districtId=-1&lineId=-1&hallType=-1&brandId=-1&serviceId=-1&areaId=-1&stationId=-1&item=&updateShowDay=true&reqId=1661137243955&cityId=30&lat=22.62996827165868&lng=113.83206564257725&optimus_uuid=A52DCFB021BA11EDBFF1953403463E7E6E4A2FED2E2A452A8271B88038A2F72A&optimus_risk_level=71&optimus_code=10";
    // axios.get(url).then((res) => {
    //   console.log("===", res);
    // });
  },
};
</script>
